﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="UsersAdmin.aspx.cs" Inherits="SystemAdmin" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

<asp:Content ID="BodyContent" ContentPlaceHolderID="MainContent" Runat="Server">

<asp:UpdatePanel runat="server"> 
<ContentTemplate>

    <asp:Panel ID="emptyPanel" runat="server" visible="false">
        <div align="center">
            <h1 >SYSTEM ADMINISTRATION</h1>
        </div>        
    </asp:Panel>

    <asp:Panel ID="systemUsersPanel" runat="server" Visible="False">
        <asp:Button ID="newUser_SystemUsersPanel_Button" runat="server" Text="Adauga un utilizator nou" Width="230px" onclick="newUser_SystemUsersPanel_Button_Click"/>
        <asp:Button ID="refreshDomainListButton" runat="server" Text="Refresh DomainList" Width="230px" onclick="refreshDomainList_Button_Click"/>
        <hr />


    </asp:Panel>
               
    

    <asp:Panel ID="editSystemUserPanel" runat="server" Visible="False">
        <div class="leftColumn">
            <div class="module">
                <div class="moduleHeader">Editarea Utilizatorului</div>
                <div class="module_content">
                    <p>
					    <label>User ID: </label>
					    <asp:Label ID="editSystemUser_ID_Label" runat="server" Text="User ID: " ></asp:Label>
				    </p>
                    <p>
					    <label>Nume: </label>
					    <asp:TextBox ID="editSystemUser_Nume_TextBox" runat="server" ></asp:TextBox>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" EnableClientScript="true" Display="Dynamic"
                            ControlToValidate="editSystemUser_Nume_TextBox" 
                            ErrorMessage="Acest cimp este obligatoriu"> * </asp:RequiredFieldValidator>   
				    </p>
                    <p>
					    <label>Prenume: </label>
                        <asp:TextBox ID="editSystemUser_Prenume_TextBox" runat="server" ></asp:TextBox>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" EnableClientScript="true" Display="Dynamic"
                            ControlToValidate="editSystemUser_Prenume_TextBox" 
                            ErrorMessage="Acest cimp este obligatoriu"> * </asp:RequiredFieldValidator>  
				    </p>
                    <p>
					    <label>Login: </label>
                        <asp:TextBox ID="editSystemUser_Login_TextBox" runat="server" ></asp:TextBox>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" EnableClientScript="true" Display="Dynamic"
                            ControlToValidate="editSystemUser_Login_TextBox" 
                            ErrorMessage="Acest cimp este obligatoriu"> * </asp:RequiredFieldValidator> 
				    </p>
                    <p>
					    <label>Password: </label>
                        <asp:TextBox ID="editSystemUser_Password_TextBox" runat="server" TextMode="Password"></asp:TextBox>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" EnableClientScript="true" Display="Dynamic"
                            ControlToValidate="editSystemUser_Password_TextBox" 
                            ErrorMessage="Acest cimp este obligatoriu"> * </asp:RequiredFieldValidator>
				    </p>
                    <p>
					    <label>Repeat Password: </label>
                        <asp:TextBox ID="editSystemUser_RepeatPassword_TextBox" runat="server" TextMode="Password"></asp:TextBox>
                        <asp:CompareValidator id="editSystemUser_Password_CompareValidator" 
                                runat="server"
                                ControlToCompare="editSystemUser_RepeatPassword_TextBox"
                                ControlToValidate="editSystemUser_Password_TextBox"
                                ErrorMessage="Atentie! Parolele nu coincid"
                                Display="Dynamic" />
				    </p>
                </div>
            </div>
        </div>

        <div class="rightColumn">
            <div class="module">
                <div class="moduleHeader"></div>
                <div class="module_content">
				    <p>
                        <label>Acest Utilizator Are dreptul de a semna contracte:</label>
                        <asp:CheckBox ID="editUserAllowAprobContractsCheckBox" runat="server" />
                    </p>
                    <p>
					    <label>Email: </label>
                        <asp:TextBox ID="editSystemUser_Email_TextBox" runat="server"></asp:TextBox>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator9" runat="server" EnableClientScript="true" Display="Dynamic"
                            ControlToValidate="editSystemUser_Email_TextBox" 
                            ErrorMessage="Acest cimp este obligatoriu"> * </asp:RequiredFieldValidator>
				    </p>
                    <p>
					    <label>Role Type: </label>
                        <asp:DropDownList ID="editSystemUser_RoleTypeDDL" runat="server"></asp:DropDownList>
				    </p>
                    <p>
					    <label>Password Status: </label>
                        <asp:DropDownList ID="editSystemUser_PasswordStatusDDL" runat="server" ></asp:DropDownList>
				    </p>
                    <p>
					    <label>Record Status: </label>
                        <asp:DropDownList ID="editSystemUser_RecordStatusDDL" runat="server"  ></asp:DropDownList>
				    </p>
                </div>
            </div>
        </div>
        <div class="clear"></div>

        <div class="centerBox" style="width:210px;">
            <asp:Button ID="editSystemUserSaveButton" runat="server" Text="Save" Width="100px" onclick="editSystemUserSaveButton_Click"   />
            <asp:Button ID="editSystemUserCancelButton" runat="server" Text="Cancel" Width="100px" onclick="editSystemUserCancelButton_Click"  CausesValidation="false" />                    
        </div>
    </asp:Panel>

</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>

